package com.tian.mapper;

import com.tian.entity.OrderUseCoupon;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface OrderUseCouponMapper {
    int deleteByPrimaryKey(Long id);

    int insert(OrderUseCoupon record);
    int insertBatch(List<OrderUseCoupon> list);

    OrderUseCoupon selectByPrimaryKey(Long id);

    List<OrderUseCoupon> selectAll();

    List<OrderUseCoupon> selectByOrderId(Long orderId);
    int countByOrderId(Long orderId);

    int updateByPrimaryKey(OrderUseCoupon record);
    int updateByOrderId(@Param("orderId") Long orderId,@Param("status") Integer status);
}